home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part1 / 6900 < prev    next >
Encoding:
Text File  |  1996-08-05  |  1.2 KB  |  44 lines

  1. Path: cyberus.ca!news
  2. From: Brian Lawless <brian@cyberus.ca>
  3. Newsgroups: comp.lang.c++
  4. Subject: Help!!   floating point error??
  5. Date: Tue, 20 Feb 1996 17:50:54 -0500
  6. Organization: University of Ottawa, Computer Science Student
  7. Message-ID: <312A504E.55A@cyberus.ca>
  8. NNTP-Posting-Host: dialup102.cyberus.ca
  9. Mime-Version: 1.0
  10. Content-Type: text/plain; charset=us-ascii
  11. Content-Transfer-Encoding: 7bit
  12. X-Mailer: Mozilla 2.0b6a (Win95; I)
  13. CC: brian@cyberus.ca
  14.  
  15. I seam to have buggered up the ability of Borland C++(ver 4.5) to read in 
  16. floating point numbers on this machine.  I am not having the same problem 
  17. when I run microsoft's visual C++ with my test code on the same machine.  
  18. This leads me to believe that the problem is isoloated with the Borland C++ 
  19. settings.
  20.  
  21. This is my very simple test code that I am using to track down this pesky 
  22. problem.
  23.  
  24. #include <iostream.h>
  25. int main()
  26. {
  27.     float myfloat;
  28.     cout << "Float: ";
  29.     cin >> myfloat;
  30.     cout << "\N" << myfloat;
  31.     return 0;
  32. }
  33.  
  34. result:        "floating point:overflow"
  35.  
  36. I am very,very interested in any suggestions people might have to fix the 
  37. problem or alternatively any suggestions as to suitable reference material.
  38.  
  39. Please note that I am also running Windows 95 with 8 megs of RAM.
  40.  
  41. Thanks a bunch,
  42.  
  43. Brian
  44.